package com.zoe.onelink.test.container.mybatis.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.zoe.onelink.annotation.mybatis.SpellField;
import com.zoe.onelink.common.entity.IBaseEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;

import javax.persistence.Entity;
import javax.persistence.Id;
import java.util.Date;

/**
 * <p>标题: </p>
 * <p>描述: </p>
 * <p>版权: Copyright (c) 2023</p>
 * <p>公司: 智业软件股份有限公司</p>
 *
 * @version: 1.0
 * @author: ruansheng
 * @date: 2023-01-13
 */
@Data
@Accessors(chain = true)
@Entity
public class Staff implements IBaseEntity {

    @Id
    @TableId(type = IdType.ASSIGN_ID)
    private String staffId;

    @SpellField
    private String staffName;

    private Integer staffAge;

    @ApiModelProperty("拼音码")
    @TableField("SPELL_CODE")
    private String spellCode;

    @ApiModelProperty("五笔码")
    @TableField("WBZX_CODE")
    private String wbzxCode;

    @ApiModelProperty("创建时间")
    @TableField(value = "CREATED_TIME", fill = FieldFill.INSERT)
    private Date createdTime;

    @ApiModelProperty("创建人")
    @TableField(value = "CREATOR_CODE", fill = FieldFill.INSERT)
    private String creatorCode;

    @ApiModelProperty("修改时间")
    @TableField(value = "MODIFIED_TIME", fill = FieldFill.INSERT_UPDATE)
    private Date modifiedTime;

    @ApiModelProperty("修改人")
    @TableField(value = "MODIFIER_CODE", fill = FieldFill.INSERT_UPDATE)
    private String modifierCode;
}
